<template>
	<view class="bigView">
		<view style="padding: 16px;">
			<!-- <rich-text :nodes="htmlValue"></rich-text> -->
			<u-parse :content="htmlValue" :lazyLoad="true"></u-parse>
		</view>
		<view></view>
	</view>
</template>

<script>
	import handjiaxingzheng from '@/api/handjiaxingzheng.js'
	export default{
		components:{
			
		},
		data(){
			return {
				bottom:0,
				type:0,//
				currentId:'',
				result:{},
				htmlValue:''
			}
		},
		mounted() {
			uni.getSystemInfo({success: (e) => {
				// this.StatusBar = e.statusBarHeight;
				let custom = wx.getMenuButtonBoundingClientRect();
				this.bottom = custom.bottom;
				// this.CustomBar = custom.bottom + custom.top - e.statusBarHeight;
				// this.TopHeight = this.CustomBar+100;//this.StatusBar+this.CustomBar;
			}})
		},
		onLoad(options) {
			if(options.id){
				this.currentId = options.id;
				this.queryByIdRequest()
			}
		},
		onShareAppMessage() {
			// if(Object.keys(this.userInfo).length==0){
			// 	uni.redirectTo({
			// 		url: '/pages/login/login'
			// 	})
			// 	return
			// }
			return{
				title: "航嘉行政",
				path: '/packageHome/pages/jiahangxingzheng/detail?id='+this.currentId,
				success(res) {
					console.log('分享成功', res);
				},
				fail(err) {
					
				}
			}
		},
		onShareTimeline() {
			return {
				title:'航嘉行政',
				path: '/packageHome/pages/jiahangxingzheng/detail?id='+this.currentId
			}
		},
		methods:{
			click(item) {
				this.newsListRequest(item.index+1)
			},
			scrolltolower() {
				// this.loadmore()
			},
			sureHandle(){
				uni.navigateBack()
			},
			queryByIdRequest(){
				handjiaxingzheng.queryByIdHandle({id: this.currentId}).then(res =>{
					this.result = res;
					this.htmlValue = this.result.content;
				}).catch(error =>{
				
				})
				
			},
		},
		onReady() {
			
		}
	}
</script>

<style lang="scss" scoped>
.bigView{
	width: 100vw;
	height: 100vh;
	background-color: #F7F7F7;
	display: flex;
	flex-direction: column;
}
table, td, th {
  border-color: #ddd;
  border-width: 1px;
  border-style: solid;
}
</style>